package com.tubi.test.constructor;

public class Student extends Person {
    //子类自己独特属性
    private int score;

    public Student() {
        super();
    }

    public Student(int score) {
        this.score = score;
    }

    public Student(String name, int age, int score) {
        super(name, age);
        this.score = score;
    }
    /*   public Student() {
        //子类创造之前，一定会完成父类的数据初始化
        System.out.println("我是子类空餐构造方法");
    }
    public Student(int score) {
        this.score = score;
        System.out.println("我是子类带参数构造方法");

    }
*/

    public int getScore() {
        return score;
    }

    public void setScore(int score) {
        this.score = score;
    }
}
